#ifndef					_EVENTRECEIVER_H_
#define					_EVENTRECEIVER_H_

#include "irrlicht/irrlicht.h"

#include <unordered_map>
#include "NFData/NetflixDataElement.h"

using namespace irr;
using namespace gui;

class CEventReceiver : public IEventReceiver
{
public:
	CEventReceiver();
	~CEventReceiver();

	virtual bool		OnEvent(const SEvent& event);

	int					Create(IrrlichtDevice* ptrDev);
	int					Destroy();
	int					FlagCreate() { return m_bFlagCreate; }

	void				m_setDataPtr(std::unordered_map<irr::scene::ISceneNode*, int>*);

	NetflixDataElement	m_selectedData;

private:
	IrrlichtDevice*		m_ptrDevice;
	bool				m_bFlagCreate;

	bool				m_bMouseRightPress;
	bool				m_bMouseLeftPress;

	void				m_HandleMouseEvent(const SEvent& event);
	void				m_HandleKeyEvent(const SEvent& event);
	void				m_HandleGUIEvent(const SEvent& event);

	void				m_handleScrollBarEvent(const SEvent& event);

	void				m_LButtonDown(const SEvent& event);

	std::unordered_map<irr::scene::ISceneNode*, int>*	m_dataList;

protected:
};


#endif					//_EVENTRECEIVER_H_
